﻿namespace Game {

	class Event {

		// TODO: decide what to do about touch screens with multiple touch points
		static field KEY = 1;
		static field MOUSE_MOVE = 2;
		static field MOUSE_BUTTON = 3;
		static field MOUSE_SCROLL = 4;
		static field CLOSE_BUTTON = 5;

		field _t;
		field _k;
		field _d;
		field _m;
		field _p;
		field _a;

		constructor(type, key, down, mouseButton, x, y, amount) {
			this._t = type;
			this._k = key;
			this._d = down;
			this._m = mouseButton;
			this._p = [x, y];
			this._a = amount;
		}

		property type { get { return this._t; } }
		property key { get { return this._k; } }
		property down { get { return this._d; } }
		property mouseButton { get { return this._m; } }
		property point { get { return this._p; } }
		property amount { get { return this._a; } }
	}
}
